package com.eorchis.constants;

import java.util.HashMap;
import java.util.Map;

public class DeptConstants {

	/**
	 * 省份级别简称对照，简称-depID
	 */
	public static final Map<String, String> PROVINCE_SHORT_DEPID_MAPPING = new HashMap<String, String>();
	/**
	 * 省份级别全程对照，全称-depID
	 */
	public static final Map<String, String> PROVINCE_DEPNAME_DEPID_MAPPING = new HashMap<String, String>();
	/**
	 * 省份级别简称对照，depID-简称
	 */
	public static final Map<String, String> PROVINCE_SHORT_DEPID_MAPPING_RESVERSE = new HashMap<String, String>();
	/**
	 * 省份级别简称对照，简称-全称
	 */
	public static final Map<String, String> PROVINCE_SHORT_DEPNAME_MAPPING = new HashMap<String, String>();
	/**
	 * 单位根节点ID
	 */
	public static final String DEPT_ROOT_ID = "1";
	
	/**
	 * 单位-教育
	 */
	public static final String DEPT_JY_TREEPATH = "-1/1/1989002/";
	/**
	 * 单位-国资委
	 */
	public static final String DEPT_GZW_TREEPATH = "-1/1/1992044/";
	
	/**
	 * 北京市部门编号
	 * */
	public static final String SWZZB=new String("1");
	/**
	 * 一级单位编码
	 */
	public static final String DEPT_LEVEL_CODE_LV1 = "lv1";
	/**
	 * 报名单位根节点ID
	 */
	public static final String SIGN_DEPT_ROOT_ID = "7380";
	/**
	 * 报名单位根节点treepath
	 */
	public static final String SIGN_DEPT_TREEPATH = "-1/1/7380/";
	/**
	 * 部委根节点ID
	 */
	public static final String BW_DEPT_ROOT_ID = "7390";

	/**
	 * 西城区部门ID
	 * */
	public static final String XCH_DEPT_ID=new String("1854369");
	
	/**
	 * 西城区部门treePath
	 * */
	public static final String XCH_DEPT_PATH=new String("-1/1/4618002/1854369/");
	
	public static final String[] DEPT_SHORT_NAME_ARR = new String[] { "京", "津", "冀", "晋", "蒙", "辽",
		"吉", "黑", "沪", "苏", "浙", "皖", "闽", "赣", "鲁", "豫", "鄂", "湘",
		"粤", "桂", "琼", "渝", "川", "黔", "滇", "藏", "陕", "甘", "青", "宁",
		"新", "兵团", "企业" };
	public static final String[] DEPT_NAME_ARR = new String[] { "北京市","天津市","河北省","山西省",
		"内蒙古自治区", "辽宁省", "吉林省", "黑龙江省", "上海市", "江苏省", "浙江省", "安徽省",
		"福建省", "江西省", "山东省", "河南省", "湖北省", "湖南省", "广东省", "广西壮族自治区",
		"海南省", "重庆市", "四川省", "贵州省", "云南省", "西藏自治区", "陕西省", "甘肃省",
		"青海省", "宁夏回族自治区", "新疆维吾尔族自治区", "新疆生产建设兵团", "企业" };
//	static {
//		String[] deptNameArr = new String[] { "北京市","天津市","河北省","山西省",
//				"内蒙古自治区", "辽宁省", "吉林省", "黑龙江省", "上海市", "江苏省", "浙江省", "安徽省",
//				"福建省", "江西省", "山东省", "河南省", "湖北省", "湖南省", "广东省", "广西壮族自治区",
//				"海南省", "重庆市", "四川省", "贵州省", "云南省", "西藏自治区", "陕西省", "甘肃省",
//				"青海省", "宁夏回族自治区", "新疆维吾尔族自治区", "新疆生产建设兵团", "企业" };
//		String[] deptIdArr = new String[] { "7382", "7420", "7383", "7421",
//				"7422", "7423", "7424", "7425", "7426", "7427", "7428", "7429",
//				"7430", "7431", "7432", "7433", "7434", "7435", "7436", "7437",
//				"7438", "7439", "7440", "7441", "7442", "7443", "7444", "7445",
//				"7446", "7447", "7448", "7449", "8063" };
//		for (int i = 0; i < DEPT_SHORT_NAME_ARR.length; i++) {
//			String sortName = DEPT_SHORT_NAME_ARR[i];
//			PROVINCE_SHORT_DEPID_MAPPING.put(sortName, deptIdArr[i]);
//			PROVINCE_DEPNAME_DEPID_MAPPING.put(deptNameArr[i], deptIdArr[i]);
//			PROVINCE_SHORT_DEPNAME_MAPPING.put(sortName, deptNameArr[i]);
//			PROVINCE_SHORT_DEPID_MAPPING_RESVERSE.put(deptIdArr[i], sortName);
//		}
//	}

	public static final String[] depName=new String[]{"北京市","政法","统战","宣传","国资委"};
	public static final String[] depFullName=new String[]{"中共北京市委组织部","中共北京市委政法委员会","中共北京市委统一战线工作部","中共北京市委宣传部","北京市人民政府国有资产监督管理委员会"};
	public static final Map<String,String> DEPT_NAME_CONVERT=new HashMap<String,String>();
	
	static{
		for(int i=0;i<depName.length;i++){
			DEPT_NAME_CONVERT.put(depName[i], depFullName[i]);
		}
	}
	
	public static void main(String[] args) {
		System.out.println(PROVINCE_SHORT_DEPID_MAPPING);
		System.out.println(PROVINCE_SHORT_DEPNAME_MAPPING);
		System.out.println(PROVINCE_SHORT_DEPID_MAPPING_RESVERSE);
	}
	
	public static String blackDepId[]=new String[]{"8065","8063","8043"};//下发计划黑名单
	public static String breakDepId[]=new String[]{"7679","7466"};//查询最大培训班编号时跳过此部门
	
	public static String ZDBMJG = "2";
	
	//不查询部门
	public static String NOT_DEPID = " and t.treepath not like '-1/1/1989543/%' and t.treepath not like '-1/1/8401/%' " +
			"and t.treepath not like '-1/1/2/%' and t.treepath not like '-1/1/1992044/4925318/%' and t.treepath not like '-1/1/3351329/%' " +
            "and t.treepath not like '-1/1/8400/%' and t.treepath not like '-1/1/9240/%' and  t.treepath not like '-1/1/4916291/%'" +
            "and t.treepath not like '-1/1/4925156/%' ";
	public static String NOT_DEPID_CB="9770";//选取非承办单位时过滤此部门
	/**
	 * 国资委一级单位父ID
	 */
	public static String GZW_DEP_PARENTID = "'1992046','1992134'";
	
	/**
	 * 按一级单位级别查询的二级单位
	 */
	public static String OTHER_LV1_DEPID = "'7380','7420','8783765',1841877";
}
